package com.springboot.boot02.bean;

import com.baomidou.mybatisplus.annotation.*;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
@AllArgsConstructor
@TableName("emp") //对应的是emp表
public class Emp {
    @TableId(type = IdType.AUTO)  //表示id自增长，并且id是主键所以使用@TableId
    private Integer empNo;
    @TableField("ename")
    private String ename;
    private String job;
    private Integer mgr;
    @TableField("hiredate")   //表示对应的数据库字段名是hiredate
    private String hireDate1;
    private Double sal;
    private Double comm;
    private Integer deptNo;
    @TableLogic(value = "1",delval = "0")  //代表之后的删除都是逻辑删除，并且会自动加上where empstate=1
    private Integer empState;
}
